#pragma once
#include"event/Object.h"
#include"jsonCpp/json.h"
#include<vector>

class MailController:public Object
{
public:
	MailController(Object* master);
	~MailController();

	int addMail(const std::string& title, const std::string& content,const std::string& item_type,const std::string& item_value,const std::string& item_size);
	
private:
	void c2sReceivetMail(Json::Value& message);
	void c2sGetMail(Json::Value& message);
	void c2sGetAllMail(Json::Value& message);

private:
	Object* m_master;

	int64_t m_globalId = 1;
};

